Fix vertical cursor motion when there's a display string with newline at EOL.
authorEli Zaretskii <eliz@gnu.org>
Wed, 8 May 2013 17:59:38 +0000 (20:59 +0300)
committerEli Zaretskii <eliz@gnu.org>
Wed, 8 May 2013 17:59:38 +0000 (20:59 +0300)
commit0c9b4359e877e7504912a31dda954b82201c5e3f
treea05cbe3ceaaacdf3855afc70caf3401dc1c6c95f
parent5a78adaa3cf16617c54d5f5a9f79864deacae9c9
Fix vertical cursor motion when there's a display string with newline at EOL.

 src/xdisp.c (row_for_charpos_p): New function, with code of
 cursor_row_p, but accepts an additional argument CHARPOS instead
 of using a hardcoded PT.
 (cursor_row_p): Call row_for_charpos_p with 2nd argument PT.
 (row_containing_pos): Call row_for_charpos_p instead of partially
 doing the same.  Fixes cursor positioning under longlines-mode
 when longlines-show-effect includes more than one newline, when
 moving the cursor vertically up.
src/ChangeLog
src/xdisp.c